import requser from '@/utils/request.js'
import { useTokenStore } from '@/stores/token.js';


export const articleCategoryListService = () => {
    // const tokenStore = useTokenStore();
    //   return request.get('/category',{headers:{'Authorization':tokenStore.token}});
    return requser.get('/category');
}


export const articleCategoryAddService = (categoryData) => {
    return requser.post('/category', categoryData);
}


export const articleCategoryUpdateService = (categoryData) => {
    return requser.put('/category', categoryData);
}

export const articleCategoryDeleteService = (categoryId) => {
    return requser.delete('/category?id='+id);
}